<template>
    <div class="content">
      <div class="left">
        <span>姓名: </span>
      </div>
      <div class="right">
        <el-input v-model="name" placeholder="请输入姓名" />
      </div>
    </div>
    <div class="content">
      <div class="left">
        <span>性别: </span>
      </div>
      <div class="right">
        <el-radio-group v-model="gender">
          <el-radio value="男" size="large">男</el-radio>
          <el-radio value="女" size="large">女</el-radio>
        </el-radio-group>
      </div>
    </div>
    <div class="content">
      <div class="left">
        <span>爱好: </span>
      </div>
      <div class="right">
        <el-checkbox-group v-model="likeList">
          <el-checkbox label="吃" value="吃" />
          <el-checkbox label="喝" value="喝" />
          <el-checkbox label="玩" value="玩" />
          <el-checkbox label="乐" value="乐" />
        </el-checkbox-group>
      </div>
    </div>
  
    <div class="content">
      <div class="left">
        <span>自我介绍: </span>
      </div>
      <div class="right">
        <el-input v-model="mycall" type="textarea" placeholder="请输入我的口号" />
      </div>
    </div>
  
    <div class="content">
      <div class="left">
      </div>
      <div class="right">
        <el-button type="primary" @click="submit">提交</el-button>
      </div>
    </div>
  </template>
  
  <script setup>
  import { ref } from 'vue'
  
  const name = ref('')
  const gender = ref('男')
  const likeList = ref([])
  const mycall = ref('')
  
  const submit = () => {
    alert(`我是${name.value},${gender.value},我喜欢${likeList.value},我的口号是${mycall.value}`)
  }
  
  
  </script>
  
  
  
  <style scoped>
  .content {
    margin: 20px;
    display: flex;
    width: 500px;
    align-items: center;
  }
  
  .left {
    width: 100px;
  }
  
  .right {
    flex: 1;
  }
  </style>